<html>
<head>
  <title>系统管理——用户管理</title>
  <meta name="layout" content="common_header"/>
  <link rel="stylesheet" type="text/css" href="${resource(dir: 'css', file: 'jquery.validate.css', absolute: true)}"/>
  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'jquery.metadata.pack.js', absolute: true)}"></script>
  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'jquery.validate.min.js', absolute: true)}"></script>
  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'jquery.form.min.js', absolute: true)}"></script>
  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'jquery.blockUI.min.js', absolute: true)}"></script>

  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'jquery.validate.custom.js', absolute: true)}"></script>
  <script type="text/javascript" src="${resource(dir: 'js/jquery', file: 'common.custom.js', absolute: true)}"></script>
  <script type="text/javascript">
    function save(id) {
      //jQuery("#id").val(id)
      jQuery("#submitForm").ajaxSubmit({
        success: function(response) {
          if (response == "1") {
            alert("修改成功")
          } else {
            alert("修改出错")
          }
        }
      });
    }
  </script>
</head>
<body>
<div id="man_zone">
  <form id="submitForm" name="submitForm" action="${createLink(controller: "scaffold", action: 'save', absolute: true)}" method="post">
    <input type="hidden" name="property" value="${bo?.class.simpleName}"/>
    <input type="hidden" name="id" value="${bo?.id}"/>
    <table width="99%" border="0" align="center" cellpadding="3" cellspacing="1" class="table_style">
      <tr>
        <td align="center" colspan="4" class="center_title_1">
          <b>用户信息</b>
        </td>
      </tr>
      <tr>
        <td align="center" colspan="3"><img src="${resource(dir: bo?.UPLOAD_FILE_PATH, file: bo?.headPicture, absolute: true)}" width="120" height="150"/></td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">用户名</td>
        <td width="30%" class="fillin">
          <input type="text" id="username" name="username" value="${bo?.username}"/>
        </td>
        <td width="20%" class="left_title_1">姓名</td>
        <td width="30%" class="fillin">
          <input type="text" id="name" name="name" value="${bo?.name}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">职业</td>
        <td width="30%" class="fillin">
          <input type="text" id="job" name="job" value="${bo?.job}"/>
        </td>
        <td width="20%" class="left_title_1">手机</td>
        <td width="30%" class="fillin">
          <input type="text" id="mobile" name="mobile" value="${bo?.mobile}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">固定电话</td>
        <td width="30%" class="fillin">
          <input type="text" id="telephone" name="telephone" value="${bo?.telephone}"/>
        </td>
        <td width="20%" class="left_title_1">MSN</td>
        <td width="30%" class="fillin">
          <input type="text" id="msn" name="msn" value="${bo?.msn}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">QQ</td>
        <td width="30%" class="fillin">
          <input type="text" id="qq" name="qq" value="${bo?.qq}"/>
        </td>
        <td width="20%" class="left_title_1">GTALK</td>
        <td width="30%" class="fillin">
          <input type="text" id="gtalk" name="gtalk" value="${bo?.gtalk}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">邮箱</td>
        <td width="30%" class="fillin">
          <input type="text" id="email" name="email" value="${bo?.email}"/>
        </td>
        <td width="20%" class="left_title_1">个人主页</td>
        <td width="30%" class="fillin">
          <input type="text" id="homepage" name="homepage" value="${bo?.homepage}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">概括标题</td>
        <td colspan="3" class="fillin">
          <input type="text" id="title" size="100" name="title" value="${bo?.title}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">家楼盘</td>
        <td width="30%" class="fillin">
          ${bo?.homeEstate?.name}
        </td>
        <td width="20%" class="left_title_1">公司楼盘</td>
        <td width="30%" class="fillin">
          ${bo?.companyEstate?.name}
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">可用资金</td>
        <td width="30%" class="fillin">
          <input type="text" id="availableMoney" name="availableMoney" value="${bo?.availableMoney}"/>
        </td>
        <td width="20%" class="left_title_1">可用积分</td>
        <td width="30%" class="fillin">
          <input type="text" id="availablePoint" name="availablePoint" value="${bo?.availablePoint}"/>
        </td>
      </tr>
      <tr>
        <td width="20%" class="left_title_1">可用点券</td>
        <td width="30%" class="fillin">
          <input type="text" id="availableCoupon" name="availableCoupon" value="${bo?.availableCoupon}"/>
        </td>
        <td width="20%" class="left_title_1">状态</td>
        <td width="30%" class="fillin">
          <g:radioGroup name="state" labels="['普通','经纪人','申请经纪人','申请失败']" value="${bo?.state ? bo?.state : '10'}" values="['10','20','30','40']">
            ${it.label} ${it.radio} &nbsp;
          </g:radioGroup>
        </td>
      </tr>
      <tr>
        <td align="center" colspan="4">
          <a id="doSave" href="javaScript:save()"><img src="${resource(dir: '/images/admin_ui/', file: 'save1.gif', absolute: true)}" alt="保存"/></a>
        </td>
      </tr>
    </table>

  </form>
</div>
</body>
</html>
